package com.huluobo.base.db;

import androidx.room.Dao;
import androidx.room.Delete;
import androidx.room.Insert;
import androidx.room.OnConflictStrategy;
import androidx.room.Query;
import androidx.room.Update;

import com.huluobo.base.bean.UserBeanResult;

/**
 * Created by LC on 2024/10/10.
 */
@Dao
public interface UserDao {
    @Insert(onConflict = OnConflictStrategy.REPLACE)
    void insertUserInfo(UserBeanResult.UserBean userBean);

    @Update
    void updateUserInfo(UserBeanResult.UserBean userBean);

    @Delete
    void deleteUserInfo(UserBeanResult.UserBean userBean);

    @Query("select * from user_info where username = :name")
    UserBeanResult.UserBean queryUserInfoByName(String name);
}
